package demo2;
class Student {
    public String name;
    public int age;

    public Student(String name, int age) {
        this.name = name;
        this.age = age;
    }

    @Override
    public String toString() {
        return "Student{" +
                "name='" + name + '\'' +
                ", age=" + age +
                '}';
    }

}
public class Test {
    public static void main(String[] args) {
        Student student1=new Student("zhangsan",10);
        Student student2=new Student("lisi",5);

    }
}
